package com.xmg.design23.d2_singleton;

/**
 * @Author: mazhongqing
 * @Date: 2021/3/24 15:23
 */
public class SingletonDCL {
    private static SingletonDCL singletonDCL;
    private SingletonDCL(){}
    public static SingletonDCL getInstance(){
        if(singletonDCL==null){
            synchronized (SingletonDCL.class){
                if(singletonDCL==null){
                    singletonDCL = new SingletonDCL();
                }
            }
        }
        return singletonDCL;
    }
}
